/*
 * Copyright 2025 arisgo@163.com
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.arisgo.cloud.auth.sys.service;

import com.arisgo.cloud.auth.sys.entity.Menu;
import com.arisgo.cloud.auth.sys.vo.MenuVo;
import com.arisgo.cloud.web.mybatis.service.ICloudService;
import com.arisgo.cloud.web.param.Search;

import java.util.List;

/**
 * 菜单
 *
 * @author Arisgo
 * @since 2024-06-14
 */
public interface MenuService extends ICloudService<Menu, MenuVo> {
    /**
     * 菜单管理页面，查询方法
     * 超级管理员：查看所有菜单
     * 租户所有者：查看已开通的功能包 + 默认功能包
     * 其他用户：功能包 + 角色权限 交集
     */
    List<MenuVo> treePageMenus(Search search);

    /**
     * 左侧展示菜单
     * 超级管理员和租户所有都，只通过功能包控制左侧菜单
     * 其他用户通过 功能包 + 角色权限 控制左侧菜单
     */
    List<MenuVo> treeLeftMenus(Search search);

}
